fresh_fruit = {
    "apple": 10,
    "banana": 8,
    "lemon": 5,
}


class OutOfBananas(Exception):
    pass


def slice_banana(count):
    pass


def out_of_stock():
    pass


def make_smoothies():
    pass


pieces = 0
if (count := fresh_fruit.get("banana", 0)) >= 2:
    pieces = slice_banana(count)

try:
    smoothies = make_smoothies(pieces)
except OutOfBananas:
    out_of_stock()
